<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.
-->

<div class="x_panel">
    <div class="x_title">
        <ol class="breadcrumb pull-left">
            <li><a ng-click="navigateToPath('/servers')">Servers</a></li>
            <li class="active">{{serverName}}</li>
        </ol>
        <div class="pull-right" role="group" ng-show="!settings.isNew">
            <button type="button" class="btn btn-primary" title="Cache Charts" ng-if="showChartsButton && isCache" ng-click="openCharts(server)"><i class="fa fa-bar-chart fa-fw"></i></button>
            <div class="btn-group" role="group" uib-dropdown is-open="more.isopen">
                <button type="button" class="btn btn-default dropdown-toggle" uib-dropdown-toggle aria-haspopup="true" aria-expanded="false">
                    More&nbsp;
                    <span class="caret"></span>
                </button>
                <ul class="dropdown-menu-right dropdown-menu" uib-dropdown-menu>
                    <li><a ng-click="confirmStatusUpdate()">Update Status</a></li>
                    <li ng-show="isCache(server) && !server.updPending"><a ng-click="queueServerUpdates(server)">Queue Server Updates</a></li>
                    <li ng-show="isCache(server) && server.updPending"><a ng-click="clearServerUpdates(server)">Clear Server Updates</a></li>
                    <li ng-show="isEdge(server) || isCache(server)" class="divider"></li>
                    <li><a ng-click="viewDeliveryServices()">View Delivery Services</a></li>
                    <li ng-show="isCache(server)"><a ng-click="viewConfigFiles()">View Config Files</a></li>
                </ul>
            </div>
        </div>
        <div class="clearfix"></div>
    </div>
    <div class="x_content">
        <br>
        <form name="serverForm" class="form-horizontal form-label-left" novalidate>
            <div class="form-group">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Status *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="status" class="form-control" ng-model="server.statusId" ng-options="status.id as status.name for status in statuses" ng-disabled="true"></select>
                </div>
            </div>
            <div class="form-group" ng-show="server.offlineReason.length > 0">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Offline Reason</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="offlineReason" type="text" class="form-control" ng-model="server.offlineReason" ng-maxlength="256" ng-readonly="true">
                </div>
            </div>
            <div class="form-group">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Update Pending *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="updPending" type="text" class="form-control" ng-model="server.updPending" ng-disabled="true">
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.hostName), 'has-feedback': hasError(serverForm.hostName)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Hostname *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="hostName" type="text" class="form-control" ng-model="server.hostName" ng-maxlength="100" ng-pattern="/^([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\-]*[A-Za-z0-9])$/" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.hostName, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.hostName, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.hostName, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.hostName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.domainName), 'has-feedback': hasError(serverForm.domainName)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Domain name *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="domainName" type="text" class="form-control" ng-model="server.domainName" ng-maxlength="100" ng-pattern="/^\S*$/" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.domainName, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.domainName, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.domainName, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.domainName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.cdn), 'has-feedback': hasError(serverForm.cdn)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">CDN *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="cdn" class="form-control" ng-change="onCDNChange()" ng-model="server.cdnId" ng-options="cdn.id as cdn.name for cdn in cdns" required>
                        <option value="">Select...</option>
                    </select>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.cdn, 'required')">Required</small>
                    <small ng-show="server.cdnId"><a href="/#!/cdns/{{server.cdnId}}" target="_blank">View Details&nbsp;&nbsp;<i class="fa fs-xs fa-external-link"></i></a></small>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.cachegroup), 'has-feedback': hasError(serverForm.cachegroup)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Cache Group *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="cachegroup" class="form-control" ng-model="server.cachegroupId" ng-options="cachegroup.id as cachegroup.name for cachegroup in cacheGroups" required>
                        <option value="">Select...</option>
                    </select>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.cachegroup, 'required')">Required</small>
                    <small ng-show="server.cachegroupId"><a href="/#!/cache-groups/{{server.cachegroupId}}" target="_blank">View Details&nbsp;&nbsp;<i class="fa fs-xs fa-external-link"></i></a></small>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.type), 'has-feedback': hasError(serverForm.type)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Type *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="type" class="form-control" ng-model="server.typeId" ng-options="type.id as type.name for type in types" required>
                        <option value="">Select...</option>
                    </select>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.type, 'required')">Required</small>
                    <small ng-show="server.typeId"><a href="/#!/types/{{server.typeId}}" target="_blank">View Details&nbsp;&nbsp;<i class="fa fs-xs fa-external-link"></i></a></small>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.profile), 'has-feedback': hasError(serverForm.profile)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Profile *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="profile" class="form-control" ng-model="server.profileId" ng-options="profile.id as profile.name for profile in profiles" required>
                        <option value="">Select...</option>
                    </select>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.profile, 'required')">Required</small>
                    <small ng-show="server.profileId"><a href="/#!/profiles/{{server.profileId}}" target="_blank">View Details&nbsp;&nbsp;<i class="fa fs-xs fa-external-link"></i></a></small>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.interfaceName), 'has-feedback': hasError(serverForm.interfaceName)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Interface Name *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="interfaceName" type="text" class="form-control" ng-model="server.interfaceName" ng-maxlength="45" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.interfaceName, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.interfaceName, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.interfaceName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.ipAddress), 'has-feedback': hasError(serverForm.ipAddress)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Network IP *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="ipAddress" type="text" class="form-control" ng-model="server.ipAddress" ng-maxlength="45" ng-pattern="ipRegex()" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipAddress, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipAddress, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipAddress, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.ipAddress)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.ipNetmask), 'has-feedback': hasError(serverForm.ipNetmask)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Network Subnet *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="ipNetmask" type="text" class="form-control" ng-model="server.ipNetmask" ng-maxlength="45" ng-pattern="validations.ipRegex" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipNetmask, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipNetmask, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipNetmask, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.ipNetmask)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.ipGateway), 'has-feedback': hasError(serverForm.ipGateway)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Network Gateway *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="ipGateway" type="text" class="form-control" ng-model="server.ipGateway" ng-maxlength="45" ng-pattern="ipRegex()" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipGateway, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipGateway, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ipGateway, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.ipGateway)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.interfaceMtu), 'has-feedback': hasError(serverForm.interfaceMtu)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Network MTU *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="interfaceMtu" type="number" class="form-control" placeholder="eg. 1500 or 9000" ng-model="server.interfaceMtu" ng-pattern="/^\d+$/" required autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.interfaceMtu, 'required')">Required</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.interfaceMtu, 'pattern')">Whole Number</small>
                    <span ng-show="hasError(serverForm.interfaceMtu)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.physLocation), 'has-feedback': hasError(serverForm.physLocation)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Phys Location *</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <select name="physLocation" class="form-control" ng-model="server.physLocationId" ng-options="physLocation.id as physLocation.name for physLocation in physLocations" required>
                        <option value="">Select...</option>
                    </select>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.physLocation, 'required')">Required</small>
                    <small ng-show="server.physLocationId"><a href="/#!/phys-locations/{{server.physLocationId}}" target="_blank">View Details&nbsp;&nbsp;<i class="fa fs-xs fa-external-link"></i></a></small>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.ip6Address), 'has-feedback': hasError(serverForm.ip6Address)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">IPv6 Address</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="ip6Address" type="text" class="form-control" ng-model="server.ip6Address" ng-maxlength="50" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ip6Address, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.ip6Address)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.ip6Gateway), 'has-feedback': hasError(serverForm.ip6Gateway)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">IPv6 Gateway</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="ip6Gateway" type="text" class="form-control" ng-model="server.ip6Gateway" ng-maxlength="50" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.ip6Gateway, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.ip6Gateway)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.tcpPort), 'has-feedback': hasError(serverForm.tcpPort)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">TCP Port</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="tcpPort" type="number" class="form-control" ng-model="server.tcpPort" ng-pattern="/^\d+$/" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.tcpPort, 'pattern')">Whole Number</small>
                    <span ng-show="hasError(serverForm.tcpPort)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.httpsPort), 'has-feedback': hasError(serverForm.httpsPort)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">HTTPS Port</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="httpsPort" type="number" class="form-control" ng-model="server.httpsPort" ng-pattern="/^\d+$/" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.httpsPort, 'pattern')">Whole Number</small>
                    <span ng-show="hasError(serverForm.httpsPort)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.rack), 'has-feedback': hasError(serverForm.rack)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Rack / Elevation</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="rack" type="text" class="form-control" ng-model="server.rack" ng-maxlength="64" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.rack, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.rack)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.mgmtIpAddress), 'has-feedback': hasError(serverForm.mgmtIpAddress)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Management IP Address</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="mgmtIpAddress" type="text" class="form-control" ng-model="server.mgmtIpAddress" ng-maxlength="50" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpAddress, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpAddress, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.mgmtIpAddress)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.mgmtIpNetmask), 'has-feedback': hasError(serverForm.mgmtIpNetmask)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Management IP Netmask</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="mgmtIpNetmask" type="text" class="form-control" ng-model="server.mgmtIpNetmask" ng-maxlength="45" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpNetmask, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpNetmask, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.mgmtIpNetmask)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.mgmtIpGateway), 'has-feedback': hasError(serverForm.mgmtIpGateway)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Management IP Gateway</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="mgmtIpGateway" type="text" class="form-control" ng-model="server.mgmtIpGateway" ng-maxlength="45" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpGateway, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.mgmtIpGateway, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.mgmtIpGateway)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.iloIpAddress), 'has-feedback': hasError(serverForm.iloIpAddress)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">ILO IP Address</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="iloIpAddress" type="text" class="form-control" ng-model="server.iloIpAddress" ng-maxlength="45" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpAddress, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpAddress, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.iloIpAddress)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.iloIpNetmask), 'has-feedback': hasError(serverForm.iloIpNetmask)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">ILO IP Netmask</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="iloIpNetmask" type="text" class="form-control" ng-model="server.iloIpNetmask" ng-maxlength="45" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpNetmask, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpNetmask, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.iloIpNetmask)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.iloIpGateway), 'has-feedback': hasError(serverForm.iloIpGateway)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">ILO IP Gateway</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="iloIpGateway" type="text" class="form-control" ng-model="server.iloIpGateway" ng-maxlength="45" ng-pattern="ipRegex()" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpGateway, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloIpGateway, 'pattern')">Invalid</small>
                    <span ng-show="hasError(serverForm.iloIpGateway)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.iloUsername), 'has-feedback': hasError(serverForm.iloUsername)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">ILO Username</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="iloUsername" type="text" class="form-control" ng-model="server.iloUsername" ng-maxlength="45" ng-pattern="/^\S*$/" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloUsername, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloUsername, 'pattern')">No Spaces</small>
                    <span ng-show="hasError(serverForm.iloUsername)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.iloPassword), 'has-feedback': hasError(serverForm.iloPassword)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">ILO Password</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="iloPassword" type="text" class="form-control" ng-model="server.iloPassword" ng-maxlength="45" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.iloPassword, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.iloPassword)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.routerHostName), 'has-feedback': hasError(serverForm.routerHostName)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Router Hostname</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="routerHostName" type="text" class="form-control" ng-model="server.routerHostName" ng-maxlength="256" ng-pattern="/^\S*$/" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.routerHostName, 'maxlength')">Too Long</small>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.routerHostName, 'pattern')">No Spaces</small>
                    <span ng-show="hasError(serverForm.routerHostName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="form-group" ng-class="{'has-error': hasError(serverForm.routerPortName), 'has-feedback': hasError(serverForm.routerPortName)}">
                <label class="control-label col-md-2 col-sm-2 col-xs-12">Router Port Name</label>
                <div class="col-md-10 col-sm-10 col-xs-12">
                    <input name="routerPortName" type="text" class="form-control" ng-model="server.routerPortName" ng-maxlength="256" autofocus>
                    <small class="input-error" ng-show="hasPropertyError(serverForm.routerPortName, 'maxlength')">Too Long</small>
                    <span ng-show="hasError(serverForm.routerPortName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-danger" ng-show="!settings.isNew" ng-click="confirmDelete(server)">Delete</button>
                <button type="button" class="btn btn-success" ng-disabled="serverForm.$pristine || serverForm.$invalid" ng-click="save(server)">{{settings.saveLabel}}</button>
            </div>
        </form>
    </div>
</div>
